import Vue from 'vue'
import Vuex from 'vuex'
import demo1 from './demo'
import cart from './cart'
import createPersistedState from 'vuex-persistedstate';  
Vue.use(Vuex)
export default new Vuex.Store({
	modules:{
		demo1,
		cart
	},
	 plugins: [  
	    createPersistedState({  
	      storage: window.localStorage, // 或者使用 sessionStorage 
		   paths:['demo1.count']
	    }),  
	  ]
})